package com.tgb.manager;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.tgb.dao.UserInfoDao;
import com.tgb.entity.UserInfo;
@Service
@Transactional
public class UserInfoManagerImpl implements UserInfoManager{
	@Autowired
	private UserInfoDao userInfoDao;
	public UserInfo getUserInfo(int id) {
		return userInfoDao.getUserInfo(id);
	}
	@Override
	public List<UserInfo> getAllUserInfos() {
		
		return userInfoDao.getAllUserInfos();
	}
	@Override
	public void addUserInfo(UserInfo userInfo) {
		
		userInfoDao.addUserInfo(userInfo);
	}
	@Override
	public boolean delUserInfo(int id) {
		
		return userInfoDao.delUserInfo(id);
	}
	@Override
	public boolean updateUserInfo(UserInfo userInfo) {
		
		return userInfoDao.updateUserInfo(userInfo);
	}

}
